# Maintainer: Felix Yan <felixonmars@archlinux.org>

pkgname=perl-alien-libxml2
pkgver=0.17
pkgrel=2
pkgdesc="Install the C libxml2 library on your system"
arch=('any')
license=('PerlArtistic')
url="https://metacpan.org/release/Alien-Libxml2"
depends=('libxml2' 'perl-alien-build')
makedepends=('perl-html-parser' 'perl-sort-versions' 'perl-test2-suite' 'perl-uri')
options=('!emptydirs')
source=("https://cpan.metacpan.org/authors/id/P/PL/PLICEASE/Alien-Libxml2-$pkgver.tar.gz")
sha512sums=('89f8034800f03e9e7f87871fec4da54313d0b2557efd9c4bbb2f01793e5679c6c355eb8bfcaf54540b50f9cf69e84d88835fee9b06f8b2f6c7dd7e6c6ed2c097')

build() {
  cd Alien-Libxml2-$pkgver
  perl Makefile.PL INSTALLDIRS=vendor
  make
}

check() {
  cd Alien-Libxml2-$pkgver
  make test
}

package() {
  cd Alien-Libxml2-$pkgver
  make DESTDIR="$pkgdir" install
}
